﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Net.Sockets;
using System.Net;
using System.IO;
using System.Threading;

namespace BC2CitadelDaemon
{
    class Program
    {
        

        static void Main(string[] args)
        {
            string ip = "208.167.234.85";
            int port = 48888;
            string password = "";

            

            Server s1 = new Server(ip, port, password);

            s1.MsgEvent += new NewMessage(s1_MsgEvent);
            //s1.PacketRecieved += new PacketRecievedEvent(s1_PacketRecieved);

            s1.CreateSocket();
            Thread.Sleep(1000);

            s1.Login();

            while (true)
            {
            }
        }

        static void s1_PacketRecieved(object sender, PacketEventArgs e)
        {
            throw new NotImplementedException();
        }

        static void s1_MsgEvent(object sender, MessageEventArgs e)
        {
            Console.WriteLine(e.message);
        }

        
    }
}
